package com.gk.panda.apis.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.gk.panda.apis.entity.deviceHandheldTerminal.dto.HandheldTerminalDto;
import com.gk.panda.apis.entity.deviceHandheldTerminal.dto.HandheldTerminalListDto;
import com.gk.panda.apis.entity.deviceHandheldTerminal.vo.HandheldTerminalListVo;
import com.gk.panda.pojo.DeviceHandheldTerminal;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletResponse;
import java.io.UnsupportedEncodingException;
import java.util.List;

/**
 * @ClassName: DeviceHandheldTerminalService
 * @Description: 手持终端
 * @author: Sir.yang
 * @date: 2022/11/4 15:08
 * @version: 1.0
 **/
public interface DeviceHandheldTerminalService extends IService<DeviceHandheldTerminal> {

    /**
     * @description: 获取手持终端列表分页
     * @param: [dto]
     * @return: com.baomidou.mybatisplus.extension.plugins.pagination.Page<com.gk.panda.apis.entity.DeviceHandheldTerminal.vo.HandheldTerminalListVo>
     * @date: 2022/11/4 15:18
     * @version: 1.0
     **/
    Page<HandheldTerminalListVo> getHandheldTerminalList(HandheldTerminalListDto dto);

    /**
     * @description: 修改终端设备信息
     * @param: [dto]
     * @return: java.lang.Integer
     * @date: 2022/11/4 15:23
     * @version: 1.0
     **/
    Integer changeHandheldTerminalInfo(HandheldTerminalDto dto) throws UnsupportedEncodingException;

    /**
     * @description: 新增终端设备信息
     * @param: [dto]
     * @return: java.lang.Integer
     * @date: 2022/11/4 15:23
     * @version: 1.0
     **/
    Integer saveHandheldTerminalInfo(HandheldTerminalDto dto) throws UnsupportedEncodingException;

    /**
     * @description: 删除设备信息
     * @param: [deviceId]
     * @return: java.lang.Integer
     * @date: 2022/11/4 15:24
     * @version: 1.0
     **/
    Integer removeHandheldTerminalInfo(Integer deviceId) throws UnsupportedEncodingException;

    /**
     * @description: 统计手持终端数量根据机构ID
     * @param: [orgId]
     * @return: java.lang.Integer
     * @date: 2022/11/11 15:17
     * @version: 1.0
     *
     * @param orgId*/
    Integer getHandheldTerminaCountByOrgId(List<Integer> orgId);

    /**
     * 下载手持终端导入模板
     *
     * @param response P
     */
    void downloadTemplate(HttpServletResponse response);

    /**
     * 批量导入手持终端信息
     *
     * @param file P
     * @return R
     */
    String importTerminal(MultipartFile file) throws UnsupportedEncodingException;

    /**
     * 批量导出手持终端信息
     *
     * @param response P
     */
    void exportTerminal(HttpServletResponse response);
}
